function [discount,beca,stipend] = u14_2012(math,lang,demrecode,his,sci)
%% Potificia Universidad Catolica de Valparaiso
lm=(math+lang)/2;
beca=zeros(size(lm,1),1);
stipend=zeros(size(lm,1),1);

%Premio de Honor Rector Rub'en Castro
discount=((math==850) + (lang==850) + (his==850) + (sci==850))>0;

%BVP
if demrecode==14039 || demrecode==14031 || demrecode==14011 || demrecode==14014 || demrecode==14076 || demrecode==14033 || demrecode==14032 || demrecode==14016 || demrecode==14034 || demrecode==14035 || demrecode==14041 || demrecode==14036 || demrecode==14037 || demrecode==14075
    [auxdiscount,stipend]=bvp(lm);
    discount=max(discount,auxdiscount);
end

end
